@model OrderDetailsModel
@using Nop.Core.Domain.Orders;
@using Nop.Web.Models.Order;
@using Nop.Services.Localization;

@*@if (Model.PrintMode)
    {
        <script type="text/javascript">
            jQuery(document).ready(function () {
                window.print();
            });
        </script>
    }*@
<div class="section-wrapper">
    <div class="order-details-wrapper">
        <div class="order-status-table-wrapper">
            <table class="order-status-table">
                <thead class="t-grid-header">
                    <tr><th class="t-header">@T("Account.CustomerOrders.OrderNumber")</th><th class="t-header">@T("Account.CustomerOrders.OrderStatus")</th><th class="t-header">@T("Account.CustomerOrders.OrderDate")</th><th class="t-header">@(T("Account.CustomerOrders.PaymentStatus").Text)</th><th class="t-header">@T("Account.CustomerOrders.OrderTotal")</th></tr>
                </thead>
                <tbody>
                    <tr><td class="order-id"><label>Order#:</label> @Model.Id</td><td><label>Status:</label> @Model.OrderStatus</td><td><label>Created On:</label> @Model.CreatedOn.ToShortDateString()&nbsp;@Model.CreatedOn.ToShortTimeString()</td><td><label>@(T("Account.CustomerOrders.PaymentStatus").Text):</label>@Model.PaymentStatus</td><td><label>Order Total:</label> @Model.OrderTotal</td></tr>
                </tbody>
            </table>
        </div>
        <div class="order-information">
            <h4>Order Information</h4>
            <table>
                <tbody>
                    <tr><td class="heading">@T("Account.CustomerOrders.OrderNumber")</td><td class="text">@Model.Id</td></tr>
                    <tr><td class="heading">@T("Account.CustomerOrders.OrderDate")</td><td class="text">@Model.CreatedOn.ToShortDateString()&nbsp;@Model.CreatedOn.ToShortTimeString()</td></tr>
                    <tr><td class="heading">@T("Account.CustomerOrders.ShippingMethod")</td><td class="text">@Model.ShippingMethod</td></tr>
                    <tr><td class="heading">@T("Account.CustomerOrders.PaymentMethod")</td><td class="text">@Model.PaymentMethod</td></tr>
                </tbody>
            </table>
        </div>
        <div class="order-addresses">
            @if (Model.IsShippable)
            {
                <div class="col-sm-4 shipping-address-details">
                    <h3>@T("Order.ShippingAddress")</h3>
                    <div class="name">
                        <b>@Model.ShippingAddress.FirstName @Model.ShippingAddress.LastName</b>
                    </div>
                    @if (Model.ShippingAddress.CompanyEnabled && !String.IsNullOrEmpty(Model.ShippingAddress.Company))
                    {
                    <div class="company">
                        @Model.ShippingAddress.Company
                    </div>
                    }

                    @if (Model.ShippingAddress.StreetAddressEnabled)
                    {
                    <div class="address1">
                        @Model.ShippingAddress.Address1
                    </div>
                    }
                    @if (Model.ShippingAddress.StreetAddress2Enabled && !String.IsNullOrEmpty(Model.ShippingAddress.Address2))
                    {
                    <div class="address2">
                        @Model.ShippingAddress.Address2
                    </div>
                    }

                    @if (Model.ShippingAddress.CityEnabled ||
                     Model.ShippingAddress.StateProvinceEnabled ||
                     Model.ShippingAddress.ZipPostalCodeEnabled)
                    {
                        if (Model.ShippingAddress.CityEnabled)
                        {

                    @Model.ShippingAddress.City<text>, </text>

                        }
                        if (Model.ShippingAddress.StateProvinceEnabled)
                        {
                    @Model.ShippingAddress.StateProvinceName<text>, </text>

                        }
                    <br />
                        if (Model.ShippingAddress.CountryEnabled && !String.IsNullOrEmpty(Model.ShippingAddress.CountryName))
                        {
                    @Model.ShippingAddress.CountryName<text>, </text>
                        }
                    }

                    @if (Model.ShippingAddress.ZipPostalCodeEnabled)
                    {
                    @Model.ShippingAddress.ZipPostalCode
                    }
                    <div class="email">
                        @Model.ShippingAddress.Email
                    </div>
                    @if (Model.ShippingAddress.CellPhoneEnabled)
                    {
                    <div class="phone">
                        @Model.ShippingAddress.CellPhoneNumber
                    </div>
                    }
                    @if (Model.ShippingAddress.PhoneEnabled)
                    {
                    <div class="phone">
                        @Model.ShippingAddress.PhoneNumber
                    </div>
                    }
                    @if (Model.ShippingAddress.FaxEnabled)
                    {
                    <div class="fax">
                        @Model.ShippingAddress.FaxNumber
                    </div>
                    }

                </div>

            }
            <div class="col-sm-4 billing-address-details">
                <h3>@T("Order.BillingAddress")</h3>
                <div class="name">
                    <b>@Model.BillingAddress.FirstName @Model.BillingAddress.LastName</b>
                </div>
                @if (Model.BillingAddress.CompanyEnabled && !String.IsNullOrEmpty(Model.BillingAddress.Company))
                {
                <div class="company">
                    @Model.BillingAddress.Company
                </div>
                }
                @if (Model.BillingAddress.StreetAddressEnabled)
                {
                <div class="address1">
                    @Model.BillingAddress.Address1
                </div>
                }
                @if (Model.BillingAddress.StreetAddress2Enabled && !String.IsNullOrEmpty(Model.BillingAddress.Address2))
                {
                <div class="address2">
                    @Model.BillingAddress.Address2
                </div>
                }
                @if (Model.BillingAddress.CityEnabled ||
                 Model.BillingAddress.StateProvinceEnabled ||
                 Model.BillingAddress.ZipPostalCodeEnabled)
                {
                    if (Model.BillingAddress.CityEnabled)
                    {
                @Model.BillingAddress.City<text>, </text>
                    }
                    if (Model.BillingAddress.StateProvinceEnabled)
                    {
                @Model.BillingAddress.StateProvinceName<text>, </text>
                    }
                <br />
                    if (Model.BillingAddress.CountryEnabled && !String.IsNullOrEmpty(Model.BillingAddress.CountryName))
                    {
                @Model.BillingAddress.CountryName<text>, </text>
                    }
                    if (Model.BillingAddress.ZipPostalCodeEnabled)
                    {
                @Model.BillingAddress.ZipPostalCode
                    }
                }
                <div class="email">
                    @Model.BillingAddress.Email
                </div>
                @if (Model.BillingAddress.CellPhoneEnabled)
                {
                <div class="phone">
                    @Model.BillingAddress.CellPhoneNumber
                </div>
                }
                @if (Model.BillingAddress.PhoneEnabled)
                {
                <div class="phone">
                    @Model.BillingAddress.PhoneNumber
                </div>
                }
                @if (Model.BillingAddress.FaxEnabled)
                {
                <div class="fax">
                    @Model.BillingAddress.FaxNumber
                </div>
                }

                @if (!String.IsNullOrEmpty(Model.VatNumber))
                {
                <div class="vat">
                    <div class="vat-label">
                        <b>@T("Order.VATNumber")</b>
                    </div>
                    <div class="vat-value">
                        @Model.VatNumber
                    </div>
                </div>
                }

                @if (Model.DisplayPurchaseOrderNumber)
                {
                <div class="po">
                    <div class="po-label">
                        <b>@T("Order.PurchaseOrderNumber")</b>
                    </div>
                    <div class="po-value">
                        @Model.PurchaseOrderNumber
                    </div>
                </div>
                }
            </div>

            <div class="col-sm-4 order-total-details">
                <h3>@T("Order.OrderTotal")</h3>
                <table class="cart-total table order-details-table">

                    <tbody>
                        <tr>
                            <td class="cart-total-left">
                                @T("Order.SubTotal"):
                            </td>
                            <td class="cart-total-right">
                                <span class="nobr">
                                    @Model.OrderSubtotal
                                </span>
                            </td>
                        </tr>
                        @if (!string.IsNullOrEmpty(Model.OrderSubTotalDiscount))
                        {
                        <tr>
                            <td class="cart-total-left">
                                @T("Order.SubTotalDiscount"):
                            </td>
                            <td class="cart-total-right">
                                <span class="nobr">
                                    @Model.OrderSubTotalDiscount
                                </span>
                            </td>
                        </tr>
                        }
                        @if (Model.IsShippable)
                        {
                        <tr>
                            <td class="cart-total-left">
                                @T("Order.Shipping"):
                            </td>
                            <td class="cart-total-right">
                                <span class="nobr">
                                    @Model.OrderShipping
                                </span>
                            </td>
                        </tr>
                        }
                        @if (!string.IsNullOrEmpty(Model.PaymentMethodAdditionalFee))
                        {
                        <tr>
                            <td class="cart-total-left">
                                @T("Order.PaymentMethodAdditionalFee"):
                            </td>
                            <td class="cart-total-right">
                                <span class="nobr">
                                    @Model.PaymentMethodAdditionalFee
                                </span>
                            </td>
                        </tr>
                        }
                        @if (Model.DisplayTaxRates && Model.TaxRates.Count > 0)
                        {
                            foreach (var taxRate in Model.TaxRates)
                            {
                        <tr>
                            <td class="cart-total-left">
                                @string.Format(T("Order.TaxRateLine").Text, taxRate.Rate):
                            </td>
                            <td class="cart-total-right">
                                <span class="nobr">
                                    @taxRate.Value
                                </span>
                            </td>
                        </tr>
                            }
                        }

                        @if (Model.DisplayTax)
                        {
                        <tr>
                            <td class="cart-total-left">
                                @T("Order.Tax"):
                            </td>
                            <td class="cart-total-right">
                                <span class="nobr">
                                    @Model.Tax
                                </span>
                            </td>
                        </tr>
                        }
                        @if (!string.IsNullOrEmpty(Model.OrderTotalDiscount))
                        {
                        <tr>
                            <td class="cart-total-left">
                                @T("Order.TotalDiscount"):
                            </td>
                            <td class="cart-total-right">
                                <span class="nobr">
                                    @Model.OrderTotalDiscount
                                </span>
                            </td>
                        </tr>
                        }
                        @if (Model.GiftCards.Count > 0)
                        {
                            foreach (var gc in Model.GiftCards)
                            {
                        <tr>
                            <td class="cart-total-left">
                                @string.Format(T("Order.GiftCardInfo").Text, gc.CouponCode):
                            </td>
                            <td class="cart-total-right">
                                <span class="nobr">
                                    @gc.Amount
                                </span>
                            </td>
                        </tr>
                            }
                        }
                        @if (Model.RedeemedRewardPoints > 0)
                        {
                        <tr>
                            <td class="cart-total-left">
                                @string.Format(T("Order.RewardPoints").Text, Model.RedeemedRewardPoints):
                            </td>
                            <td class="cart-total-right">
                                <span class="nobr">
                                    @Model.RedeemedRewardPointsAmount
                                </span>
                            </td>
                        </tr>
                        }
                        <tr>
                            <td class="cart-total-left">
                                <b>
                                    @T("Order.OrderTotal"):
                                </b>
                            </td>
                            <td class="cart-total-right">
                                <span class="nobr">
                                    <b>
                                        @Model.OrderTotal
                                    </b>
                                </span>
                            </td>
                        </tr>
                    </tbody>
                </table>
            </div>
            <div class="clear"></div>
        </div>

        @if (!String.IsNullOrEmpty(Model.PickUpTimeShow))
        {
            <div class="order-scheduledtime">
                <div class="col-xs-12">
                    <h3>Scheduled Delivery Time</h3>
                    <div>
                        @Model.PickUpTimeShow
                    </div>
                </div>
                <div class="clear"></div>
            </div>
        }

        @if (Model.CheckoutAttributeViewModel != null && Model.CheckoutAttributeViewModel.Count > 0)
        {
            <div class="order-attributes">
                <div class="col-xs-12">
                    <table style="width:100%;">
                        @foreach (var item in Model.CheckoutAttributeViewModel)
                        {
                            <tr>
                                <td colspan="2" class="left">
                                    <h3 style="text-transform:capitalize;">@item.Key</h3>
                                </td>
                            </tr>
                            foreach (var attribute in item.Value)
                            {
                                <tr>
                                    <td style="width: 100px;">
                                        <label for="@attribute.Name" title="" style="text-transform:capitalize;">@attribute.Name</label>:
                                    </td>
                                    <td title="@attribute.Value">@attribute.Value</td>
                                    @*@if (!string.IsNullOrEmpty(attribute.Value) && attribute.Name == "message")
                                        {
                                            <td title="@attribute.Value">
                                                @(attribute.Value.Length > 20 ? attribute.Value.Substring(0, 20) + "..." : attribute.Value)
                                            </td>
                                        }
                                        else
                                        {
                                            <td title="@attribute.Value">@attribute.Value</td>
                                        }*@
                                </tr>
                            }
                        }
                    </table>
                </div>
                <div class="clear"></div>
            </div>
        }

        @if (Model.IsShippable && Model.ShowShipments)
        {
            <div class="order-shipments">
                <div class="col-xs-12">
                    <h3>Shipments</h3>
                    @if (Model.Shipments.Count > 0)
                    {
                        var i = 1;
                        foreach (var s in Model.Shipments)
                        {
                            <div class="order-shipment">
                                <h4>
                                    Shipment @i - @s.TrackingNumber @if (!String.IsNullOrEmpty(s.DisplayedStatus))
                                    {<span>- </span><span class="">@s.DisplayedStatus</span>}
                                </h4>
                                @if (s.ShippedDate.HasValue)
                                {
                                    <p>Shipped: @s.ShippedDate.Value.ToShortDateString()&nbsp;@s.ShippedDate.Value.ToShortDateString()</p>
                                }
                                @if (s.DeliveryDate.HasValue)
                                {
                                    <p>Delivered: @s.DeliveryDate.Value.ToShortDateString()&nbsp;@s.DeliveryDate.Value.ToShortDateString()</p>
                                }
                                @if (s.ShipmentEvents != null && s.ShipmentEvents.Count > 0)
                                {
                                    <table class="table">
                                        <thead>
                                            <tr><th>Date & Time</th><th>Package Status</th><th>Location</th></tr>
                                        </thead>
                                        <tbody>
                                            @foreach (var ev in s.ShipmentEvents)
                                            {
                                                <tr><td>@ev.Date @ev.Time</td><td>@ev.EventName</td><td>@ev.Location</td></tr>
                                            }
                                        </tbody>
                                    </table>
                                }
                            </div>
                                i++;
                        }
                    }
                    else
                    {
                        <div>We are preparing your shipments. Once Your shipments are set, you will be able to see them here.</div>
                    }
                </div>
                <div class="clear"></div>
            </div>
        }
        @if (Model.Items.Count > 0)
        {
            <div class="order-products">
                <div class="products col-xs-12">
                    <h3>Product(s) Ordered:</h3>
                    <table class="products-box-print">

                        @foreach (var item in Model.Items)
                        {
                            <tr class="cart-store-item">

                                <td class="cart-store-items-image">
                                    <div class="cart-store-item-image">
                                        @if (!Model.PrintMode)
                                        {
                                            <a href="@Url.RouteUrl("Product", new { SeName = item.ProductSeName })" title="View details"><img alt="@item.PictureModel.AlternateText" src="@item.PictureModel.ImageUrl" title="@item.PictureModel.Title" class="img-responsive" /></a>
                                        }
                                        else
                                        {
                                            <img alt="@item.PictureModel.AlternateText" src="@item.PictureModel.ImageUrl" title="@item.PictureModel.Title" />
                                        }
                                    </div>
                                </td>
                                <td class="cart-store-item-productname">
                                    <div class="cart-store-item-name">
                                        @if (!Model.PrintMode)
                                        {
                                            <a href="@Url.RouteUrl("Product", new { SeName = item.ProductSeName })" title="View details"><h4>@item.ProductName</h4></a>
                                        }
                                        else
                                        {
                                            <h4>@item.ProductName</h4>
                                        }
                                    </div>
                                    @if (Model.ShowSku)
                                    {
                                        @item.Sku
                                    }


                                    @if (!String.IsNullOrEmpty(item.AttributeInfo))
                                    {
                                        <div class="attributes">
                                            @Html.Raw(item.AttributeInfo)
                                        </div>
                                    }
                                </td>
                                <td class="cart-page-qty">
                                    <b>Quantity</b><br />
                                    <span>@item.Quantity</span>
                                </td>
                                <td class="cart-page-total">
                                    <b>Subtotal</b><br />
                                    <span class="product-subtotal">@item.SubTotal</span>
                                </td>
                                <td class="cart-page-review">
                                    @if (item.CanReview)
                                    {
                                        @*<input type="button" class="btn btn-normal" value="Write Review" data-toggle="modal" data-target="#modal-review-product-@item.Id" />*@
                                        <span class="btn btn-normal"><a href="/productreviews/@item.ProductId">Write Review</a></span>
                                        @*<div id="modal-review-product-@item.Id" class="modal fade" role="dialog">
                                                <div class="modal-dialog">
                                                    <div class="modal-content">
                                                        <div class="modal-header">
                                                            <h4 class="modal-title">Cancel Order #@Model.Id</h4>
                                                        </div>

                                                        <div class="modal-body">
                                                            <div class="modal-loading">
                                                                <div class="order-cancel-loading">
                                                                    <img class="loading-gif" src="/content/images/loading.gif" />
                                                                    <img class="loading-svg" src="/content/images/loading.svg" />
                                                                </div>
                                                            </div>
                                                            <div class="content">
                                                                <p>Are you sure you want to cancel this order? You will not be able to cancel an order if any product within the order has been shipped.</p>
                                                            </div>
                                                        </div>
                                                        <div class="modal-footer">
                                                            <div class="content">
                                                                <button type="button" class="btn btn-danger order-cancel-button" data-url="@Url.RouteUrl("AjaxCancelOrder", new { orderId = Model.Id })">Yes</button>
                                                                <button type="button" class="btn btn-normal" data-dismiss="modal">No</button>
                                                            </div>
                                                        </div>
                                                    </div>
                                                </div>
                                            </div>*@
                                    }
                                </td>
                            </tr>
                        }
                    </table>
                </div>
                <div class="clear"></div>
            </div>
        }

        @if (Model.DisplayPdfInvoice || Model.CanCancel || Model.CanReturn)
        {
            <div class="order-buttons col-xs-12">
                <div class="order-buttons-wrapper">
                    @if (Model.DisplayPdfInvoice)
                    {
                        <a class="btn btn-normal pdf-order-button" href='@Url.RouteUrl("GetOrderPdfInvoice", new { orderId = Model.Id })' )">@T("Order.GetPDFInvoice")</a>
                    }
                    @if (Model.CanCancel)
                    {
                        <button type="button" class="btn btn-normal cancel-order-button" data-toggle="modal" data-target="#modal-cancel-order-@Model.Id" data-backdrop="static" data-keyboard="false">@T("Order.CancelOrder")</button>
                        <div id="modal-cancel-order-@Model.Id" class="modal fade" role="dialog">
                            <div class="modal-dialog">
                                <div class="modal-content">
                                    <div class="modal-header">
                                        <h4 class="modal-title">Cancel Order #@Model.Id</h4>
                                    </div>

                                    <div class="modal-body">
                                        <div class="modal-loading">
                                            <div class="order-cancel-loading">
                                                <img class="loading-gif" src="/content/images/loading.gif" />
                                                <img class="loading-svg" src="/content/images/loading.svg" />
                                            </div>
                                        </div>
                                        <div class="content">
                                            <p>Are you sure you want to cancel this order? You will not be able to cancel an order if any product within the order has been shipped.</p>
                                        </div>
                                    </div>
                                    <div class="modal-footer">
                                        <div class="content">
                                            <button type="button" class="btn btn-danger order-cancel-button" data-url="@Url.RouteUrl("AjaxCancelOrder", new { orderId = Model.Id })">Yes</button>
                                            <button type="button" class="btn btn-normal" data-dismiss="modal">No</button>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                    }

                    @if (Model.CanReturn)
                    {
                        <button type="button" class="btn btn-normal return-order-button" data-toggle="modal" data-target="#modal-return-order-@Model.Id" data-backdrop="static" data-keyboard="false">@T("Order.ReturnRequest")</button>
                        <div id="modal-return-order-@Model.Id" class="modal fade" role="dialog" data-url="@Url.Action("AjaxReturnRequest", "ReturnRequest", new { area = "commerce" })">
                            <div class="modal-dialog">
                                <div class="modal-content">
                                    <div class="modal-header">
                                        <h4 class="modal-title">Request Product Return</h4>
                                    </div>

                                    <div class="modal-body">
                                        <div class="modal-loading">
                                            <div class="order-return-loading">
                                                <img class="loading-gif" src="/content/images/loading.gif" />
                                                <img class="loading-svg" src="/content/images/loading.svg" />
                                            </div>
                                        </div>
                                        <div class="content modal-body-content">

                                        </div>
                                    </div>
                                    <div class="modal-footer">
                                        <div class="content">
                                            <button type="button" class="btn btn-normal return-request-next">Next</button>
                                            <button type="button" class="btn btn-normal return-request-submit">@T("ReturnRequests.Submit")</button>
                                            <button type="button" class="btn btn-normal return-request-cancel" data-dismiss="modal">Cancel and Close</button>
                                            <button type="button" class="btn btn-normal return-request-refresh" data-dismiss="modal">Close</button>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                    }

                    @if (Model.PaymentStatus == "Pending" && Model.OrderStatus == "Pending")
                    {
                        <input type="button" class="btn btn-danger" value="Payment" />
                    }
                </div>
            </div>
        }

        <script>
            function goBack() {
                window.history.back();
            }

            function printPage() {
                window.print();
            }
            $(".order-cancel-button").live("click", function () {
                var _this = $(this);
                var url = $(this).attr("data-url");
                if (url != null) {
                    $(this).closest(".modal-content").find(".modal-loading").fadeIn(200);
                    $(this).closest(".modal-content").find(".modal-body .content, .modal-footer .content").hide();
                    $.ajax({
                        url: url,
                        type: "POST",
                        dataType: "JSON"
                    }).done(function (data) {
                        _this.closest(".modal-content").find(".modal-loading").fadeOut(200);
                        _this.closest(".modal-content").find(".modal-body .content, .modal-footer .content").show();
                        _this.closest(".modal-content").find(".modal-body .content").html(data.html);
                        _this.closest(".modal-content").find(".modal-footer .content").html(data.buttons);
                    });
                }
            });
            $("#modal-return-order-@Model.Id").live("show.bs.modal", function (e) {
                $("#modal-return-order-@Model.Id .return-request-cancel").show();
                submitReturnRequestPage($("#modal-return-order-@Model.Id").attr("data-url"));
            }).live("hide.bs.modal", function (e) {
                $("#modal-return-order-@Model.Id .return-request-submit, #modal-return-order-@Model.Id .return-request-next, #modal-return-order-@Model.Id .return-request-refresh").hide();
            });
            $("#modal-return-order-@Model.Id .return-request-submit, #modal-return-order-@Model.Id .return-request-next").live("click", function () {
                if ($("#modal-return-order-@Model.Id .modal-body-content form").length) {
                    var form = $("#modal-return-order-@Model.Id .modal-body-content form");
                    submitReturnRequestPage(form.attr("action"), form.serializeArray());
                }
            });
            @*$("#modal-return-order-@Model.Id .return-request-refresh").live("click", function () {
        $(".modal").modal('hide');
        if (typeof requestOrder === "function") {
            $("html, body").stop().animate({ scrollTop: 0 }, 200);
            requestOrder('@Model.Id', false);
        }
    });*@
            function submitReturnRequestPage(url, d) {
                if (url != null && url != "") {
                    $("#modal-return-order-@Model.Id .modal-body-content").empty();
                    $("#modal-return-order-@Model.Id .modal-loading").show();
                    $("#modal-return-order-@Model.Id .return-request-submit, #modal-return-order-@Model.Id .return-request-next, #modal-return-order-@Model.Id .return-request-refresh").hide();
                    if (d == null) {
                        d = $("<form></form>").serializeArray();
                    }
                    d.push({ name: "OrderId", value: '@Model.Id' });
                    $.ajax({
                        url: url,
                        type: "POST",
                        data: d
                    }).done(function (data) {
                        $("#modal-return-order-@Model.Id .modal-loading").hide();
                        $("#modal-return-order-@Model.Id .modal-body-content").html(data.html);
                        if (data.message) {
                            $("#modal-return-order-@Model.Id .modal-body-content").prepend(data.message);
                        }
                        if (data.success == true) {
                            if (data.final == true) {
                                $("#modal-return-order-@Model.Id .return-request-submit").show();
                            } else if (data.complete == true) {
                                $("#modal-return-order-@Model.Id .return-request-refresh").show();
                                $("#modal-return-order-@Model.Id .return-request-cancel").hide();
                            } else {
                                $("#modal-return-order-@Model.Id .return-request-next").show();
                            }

                        }
                    });
                }
            }
        </script>

        <div class="clear"></div>
    </div>

</div>
